package yesjava.news.utils;

import cn.hutool.extra.mail.MailUtil;

import java.util.List;

public class EmailUtil {
    public static void sendEmail(List<String> address, String title,String content,boolean isHtml){
        new Thread(() -> {
            try {
                MailUtil.send(address, title, content, isHtml);
            } catch (Exception e) {
                e.printStackTrace();
                System.err.println("邮件发送错误");
            }
        }  ).start();
    }
}
